package com.guigu.service;

import org.springframework.stereotype.Component;

@Component
public class ServiceB{
    private ServiceA serviceA;
    
//    public ServiceB(ServiceA serviceA){
//        this.serviceA = serviceA;
//    }

    public void setServiceA(ServiceA serviceA) {
        this.serviceA = serviceA;
        System.out.println("B里面注入A");
    }
}
